#pragma once

#include "Define.h"

class ShareClass CMemPool
{
public:
	CMemPool(size_t size, size_t growStep);
	~CMemPool();
	
	void* malloc();
	void free(void* pAddress);

private:
	size_t m_size;
	size_t m_growStep;
	void* m_freeHead;
	void* m_allHead;
	size_t m_freeSize;
	size_t m_mallocCount;
};

